Setting `axes.linewidth` without changing the `rcParams` global dict
Posted
by mlvljr
on Stack Overflow
See other posts from Stack Overflow
or by mlvljr
Published on 2010-03-31T13:58:18Z
Indexed on
2010/03/31
21:33 UTC
Read the original article
Hit count: 208
So, it seems one cannot do the following (it raises an error, since axes
does not have a set_linewidth
method):
axes_style = {'linewidth':5}
axes_rect = [0.1, 0.1, 0.9, 0.9]
axes(axes_rect, **axes_style)
and has to use the following old trick instead:
rcParams['axes.linewidth'] = 5 # set the value globally
... # some code
rcdefaults() # restore [global] defaults
Is there an easy / clean way (may be one can set x
- and y
- axes parameters individually, etc)?
P.S. If no, why?
© Stack Overflow or respective owner